//
//  NextViewController.m
//  ACFramework_Example
//
//  Created by caoyq on 2020/9/30.
//  Copyright © 2020 honeycao. All rights reserved.
//

#import "NextViewController.h"

@interface NextViewController ()

@end

@implementation NextViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.title = [@(self.navigationController.viewControllers.count) stringValue];
    self.view.backgroundColor = [UIColor lightGrayColor];
    self.navigationController.navigationBar.barTintColor = [UIColor greenColor];
    
    UIButton *btn = [UIButton buttonWithType:UIButtonTypeCustom];
    btn.frame = CGRectMake(0, 0, 100, 60);
    btn.center = self.view.center;
    [btn setTitle:@"点击修改标题" forState:UIControlStateNormal];
    [btn addTarget:self action:@selector(handleClickButton) forControlEvents:UIControlEventTouchUpInside];
    btn.backgroundColor = [UIColor blueColor];
    [self.view addSubview:btn];
}

- (void)handleClickButton {
    self.title = @"88888";
    if (self.clickBlock) {
        self.clickBlock();
    }
}

@end
